Mass spectrometers are widely used for the detection of chemical substances. In a typical mass spectrometer, molecules or particles are excited or ionized, and these excited species often break down to form ions of smaller mass or react with other species to form other characteristic ions. The ion formation pattern can be interpreted by a system operator to infer the identity of the compound.